//
//  naviViewController.m
//  bookKTVMerchant
//
//  Created by edz on 2019/7/22.
//  Copyright © 2019年 edz. All rights reserved.
//

#import "naviViewController.h"

@interface naviViewController ()

@end

@implementation naviViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
}

- (void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated{
    
    [self.navigationBar setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:[UIColor blackColor], NSForegroundColorAttributeName, [UIFont systemFontOfSize:16], NSFontAttributeName, nil]];
    
    //导航栏颜色
//    [UINavigationBar appearance].barTintColor=[UIColor colorWithRed:26/255.0 green:74/255.0 blue:199/255.0 alpha:1.0];
//
    [UINavigationBar appearance].barTintColor=[UIColor whiteColor];
    
    if(self.childViewControllers.count > 0) {
        
        viewController.hidesBottomBarWhenPushed = YES;
        
        viewController.navigationItem.leftBarButtonItem=[[UIBarButtonItem alloc]initWithImage:[UIImage imageNamed:@"navBack"] style:UIBarButtonItemStylePlain target:self action:@selector(navigationBackClick)];
        //   viewController.navigationItem.leftBarButtonItem.tintColor=[UIColor whiteColor];
//        viewController.navigationItem.leftBarButtonItem.tintColor=[UIColor blackColor];
        
        
    }
    
    [super pushViewController:viewController animated:animated];
    
    
    
    
}

#pragma mark - 返回按钮
- (void)navigationBackClick{
  //  [self popViewControllerAnimated:YES];
    
    [self popViewControllerAnimated:YES];
    
}




/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
